package io;

import java.io.*;
import java.nio.charset.StandardCharsets;

public class PwDemo {
    public PwDemo() throws FileNotFoundException {
    }

    public static void main(String[] args) throws FileNotFoundException {
        /*
        PrintWriter pw = new PrintWriter("pw.txt");
        pw.println("写信告诉我今天是什么颜色放大了回复拉链位");
        pw.println("fdakuwfgkafwa");
        System.out.println("写出完毕");
        pw.close();

         */

        FileOutputStream fos = new FileOutputStream("pw2.txt");
        OutputStreamWriter osw = new OutputStreamWriter(fos, StandardCharsets.UTF_8);
        BufferedWriter bw = new BufferedWriter(osw);
        PrintWriter pw = new PrintWriter(bw);
        pw.println("faohfaohfoahfo");
        pw.println("f佛啊恶狗强求");
        pw.close();
    }


}
